-
Notifications
You must be signed in to change notification settings - Fork 292
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: sourcemap sources removes webpack path #1122
Conversation
src/index.js
Outdated
if (source.startsWith('webpack/')) | ||
return '/webpack/' + source.slice(8); | ||
return sourceMapBasePrefix + source; | ||
// webpack://[namespace]/[resourcePath] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like this no longer accounts for the webpack:///webpack:///
case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, look at output.devtoolModuleFilenameTemplate , I think using webpack config is a better choice
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! Is there a way to add a test to confirm this fixes the issue?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure! I've added tests
test/unit/minify update output
test/unit/minify-sourcemap-register test/unit/minify-v8cache-sourcemap-register
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! 🎉
🎉 This PR is included in version 0.38.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
The source is now in the format
webpack://[namespace]/[resourcePath]